<template>
	<view class="myTabs_container frostedGlass" :style="{'top': fixedTopStyle}" v-show="showTabs">
		<u-tabs :list="get_scrollList" @click="get_detailed" :inactiveStyle="itemStyle" :activeStyle="okItemStyle" />
	</view>
</template>

<script>
	import props from './props.js'
	export default {
		name: "my-tabs",
		data() {
			return {
				itemStyle: {
					color: "#333",
				},
				okItemStyle: {
					color: "#000",
				}
			};
		},
		props: props,
		methods: {
			get_detailed(item) {
				uni.$u.route({
					url: 'page_detailed/detailed/detailed',
					params: {
						id: item.id,
						name: item.name
					}
				})
			}
		},
		computed: {
			fixedTopStyle() {
				return typeof(this.fixedTop) === 'number' ? `${this.fixedTop}px` : this.fixedTop;
			},
			get_scrollList() {
				return this.$store.state.isTypeWallpaperList;
			}
		},
	}
</script>

<style lang="scss" scoped>
	.myTabs_container {
		position: fixed;
		left: 0;
		right: 0;
		z-index: 11;
		background-color: rgba(225, 225, 225, 0.35);
	}
</style>
